$OpenBSD: patch-base_sys_info_posix_cc,v 1.5 2017/04/19 05:16:46 robert Exp $
--- base/sys_info_posix.cc.orig.port	Wed Oct 12 21:02:53 2016
+++ base/sys_info_posix.cc	Wed Oct 19 12:55:56 2016
@@ -140,6 +140,17 @@ int64_t SysInfo::AmountOfVirtualMemory() {
 }
 
 // static
+int64_t SysInfo::AmountOfAvailablePhysicalMemory() {
+  long available_pages = sysconf(_SC_AVPHYS_PAGES);
+  long page_size = sysconf(_SC_PAGE_SIZE);
+  if (available_pages == -1 || page_size == -1) {
+    NOTREACHED();
+    return 0;
+  }
+  return static_cast<int64_t>(available_pages) * page_size;
+}
+
+// static
 int64_t SysInfo::AmountOfFreeDiskSpace(const FilePath& path) {
   base::ThreadRestrictions::AssertIOAllowed();
 
